Implantable Stimulator Device with Magnetic Field Sensing Circuit

ABSTRACT

An implantable pulse generator (IPG) for an implantable medical device is disclosed herein. The IPG is capable of sensing the presence of an external magnetic field, such as a magnetic field associated with magnetic resonance imaging (MRI). The IPG includes a circuit that contains a magnetic core inductor and that is configured to boost a first voltage to a second voltage and use the second voltage to drive a current through a load. In a strong magnetic field, the magnetic core of the inductor becomes magnetically saturated, causing the inductance of the inductor to sharply drop. The inductance drop can be detected, for example, by detecting an increase in the second voltage. The circuit may be a boost converter circuit used to provide a compliance voltage for operation of the IPG.

CROSS REFERENCE TO RELATED APPLICATIONS

This is a non-provisional application based on U.S. Provisional PatentApplication Ser. No. 62/393,008, filed Sep. 10, 2016, which isincorporated by reference in its entirety, and to which priority isclaimed.

FIELD OF THE INVENTION

The present invention relates to an implantable medical device. Morespecifically, the invention relates to an implantable pulse generator(IPG) for a medical device, the IPG having the ability to sense thepresence of an external magnetic field, such as a magnetic fieldassociated with magnetic resonance imaging, and to take appropriateactions to protect the patient and the IPG.

BACKGROUND

Implantable stimulation devices are devices that generate and deliverelectrical stimuli to body nerves and tissues for the therapy of variousbiological disorders, such as pacemakers to treat cardiac arrhythmia,defibrillators to treat cardiac fibrillation, cochlear stimulators totreat deafness, retinal stimulators to treat blindness, musclestimulators to produce coordinated limb movement, spinal cordstimulators to treat chronic pain, cortical and deep brain stimulatorsto treat motor and psychological disorders, and other neural stimulatorsto treat urinary incontinence, sleep apnea, shoulder subluxation, etc.FIG. 1 shows an implantable stimulation device 1 as may be used forspinal cord stimulation or deep brain stimulation. Such a device 1typically includes an Implantable Pulse Generator (IPG) 10, whichincludes a biocompatible device case 12 formed of a conductive materialsuch as titanium for example. The case 12 typically holds the circuitryand battery necessary for the IPG 10 to function, although IPGs can alsobe powered via external RF energy and without a battery. The IPG 10 iscoupled to electrodes 16 via one or more electrode leads 18, such thatthe electrodes 16 form an electrode array 20. The electrodes 16 arecarried on a flexible body which also houses the individual signal wires24 coupled to each electrode. In the illustrated embodiment, there areeight electrodes on each lead 18, although the number of leads andelectrodes is application specific and therefore can vary. The leads 18couple to the IPG 10 using lead connectors 26, which are fixed in anon-conductive header material 28, which can comprise an epoxy forexample.

FIG. 2 shows a first embodiment 201 of implantable stimulation deviceimplanted in a patient for deep brain stimulation and a secondembodiment 202 implanted in the patient for spinal cord stimulation. Fordeep brain stimulation, the IPG 10 is typically embedded in the in thepatient's chest inferior to the clavicle. The signal wires 24 are routedbeneath the skin of the patient's neck and head and the leads 18 areimplanted into the patient's brain 32. For spinal cord stimulation, theIPG 10 is typically embedded in the in the patient's buttock and theleads 18 are implanted into the patient's spinal column.

The implantable stimulation device may further comprise a handheldRemote Control (RC) (not shown) to remotely instruct the neurostimulatorto generate electrical stimulation pulses in accordance with selectedstimulation parameters. The RC is used to send data to and receive datafrom the IPG 10. For example, the RC can send programming data to theIPG 10 to dictate the therapy the IPG 10 will provide to the patient.Also, the RC can act as a receiver of data from the IPG 10, such asvarious data reporting on the IPG's status. Wireless data transferbetween the IPG 10 and the RC can take place via magnetic inductivecoupling. To implement such functionality, both the IPG 10 and the RCtypically have electrical coils that can act as the transmitter or thereceiver, thus allowing for two-way communication between the twodevices, as is well known in the art.

IPGs are routinely implanted in patients who are in need of MagneticResonance Imaging (MRI). Thus, when designing implantableneurostimulation systems, consideration must be given to the possibilitythat the patient in which neurostimulator is implanted may be subjectedto electro-magnetic forces generated by MRI scanners, which maypotentially cause damage to the neurostimulator as well as discomfort tothe patient. In particular, in MRI, spatial encoding relies onsuccessively applying magnetic field gradients. The magnetic fieldstrength is a function of position and time with the application ofgradient fields throughout the imaging process. Gradient fieldstypically switch gradient coils (or magnets) ON and OFF thousands oftimes in the acquisition of a single image in the present of a largestatic magnetic field. Present-day MM scanners can have maximum gradientstrengths of 100 mT/m and much faster switching times (slew rates) of150 mT/m/ms, which is comparable to stimulation therapy frequencies.Typical MRI scanners create gradient fields in the range of 100 Hz to 30KHz, and radio frequency (RF) fields of 64 MHz for a 1.5 Tesla scannerand 128 MHz for a 3 Tesla scanner.

The strength of the gradient magnetic field may be high enough to inducevoltages (5-10 Volts depending on the orientation of the lead inside thebody with respect to the MRI scanner) on to the stimulation lead(s) 18,which in turn, are seen by the IPG electronics. If these inducedvoltages are higher than the voltage supply rails of the IPGelectronics, there could exist paths within the IPG that could inducecurrent through the electrodes on the stimulation lead(s), which inturn, could cause unwanted stimulation to the patient due to the similarfrequency band, between the MM-generated gradient field and intendedstimulation energy frequencies for therapy, as well as potentiallydamaging the electronics within the IPG. The gradient (magnetic) fieldmay induce electrical energy within the wires of the stimulationlead(s), which may be conveyed into the circuitry of the IPG and thenout to the electrodes of the stimulation leads.

Accordingly, the IPG may feature an MM-safe mode that protects the IPG10 and the patient from damage or injury due to magnetic field-inducedelectrical energy when the patient undergoes an MRI. For example, inMRI-safe mode, the IPG may cease providing stimulation to the patient.Additionally, (or alternatively) the IPG may increase the voltage withinthe IPG to prevent unwanted induced current through the IPG. The IPG maymodify or suspend other operations, such as passive charge recovery, anoperation whereby charge is passively conveyed to AC ground by closingswitches associated with the active electrodes. Within an MRI, theclosed switches may potentially provide a path for magnetically inducedcurrents into and out of the IPG. The recovery switches are thereforeleft open during MRI-safe mode.

The IPG can be set to MM-safe mode using the RC. Additionally, some IPGscan be set to MM mode by placing a magnet against the patient's skinover the IPG. Some IPGs include internal magnetic sensors, typicallyHall effect magnetic sensors, that are capable of sensing an externalmagnetic field, such as an MM field. Hall effect magnetic sensor have alimitation in that they are unidirectional. In other words, a Halleffect magnetic sensor is only effective when it is situated in aparticular orientation with respect to the magnetic field. Therefore, aseries of three orthogonally oriented Hall effect sensors must be usedto reliably sense the presence of an external magnetic field. Such asensor design is undesirably large.

BRIEF DESCRIPTION OF THE DRAWINGS

FIG. 1 shows a medical device including an IPG.

FIG. 2 shows an embodiments of a medical devices implemented for DBS andfor SCS.

FIG. 3 shows various components of an IPG.

FIG. 4 illustrates an electrical stimulation path through a patient'stissue.

FIG. 5 illustrates a boost circuit for providing a compliance voltage.

FIG. 6 shows a circuit for detecting an external magnetic field.

FIG. 7 shows inductor current and voltage behavior for the circuitillustrated in FIG. 6.

FIG. 8 shows inductor current and voltage behavior for the circuitillustrated in FIG. 6 in the presence and absence of an externalmagnetic field.

FIG. 9 shows a process for measuring an external magnetic field.

FIG. 10 shows the relationship between inductance and external magneticfield for two sample inductors.

FIG. 11 shows a method for adjusting the duty cycle of a compliancevoltage circuit when an IPG detects an external magnetic field.

DESCRIPTION

FIG. 3 illustrates the internal components (represented as blocks) of anIPG 10 that are relevant in this disclosure. Note that IPG 10 includesmany other components that are not discussed. Each of the blocksrepresent circuits or groups of circuits that perform standard functionswithin the IPG 10.

Communication among internal components within the IPG 10 may be via oneor more digital busses 300 and analog busses 301. The microcontroller(μC, 302) functions as the master controller for all of the otherblocks. The telemetry block 303 couples to a telemetry coil 304 andincludes transceiver circuitry for communicating with an externalcontroller. The charging block 306 couples to a charging coil 307 andincludes charging circuitry for rectifying power received from anexternal charger and for charging the power source (battery, 308) in acontrolled fashion.

The microcontroller 302 is coupled to monitoring circuitry 313, whichmonitors the status of various nodes or other points throughout the IPG10. For example, the monitoring circuitry can monitor power supplyvoltages, current values, temperature and impedances of the electrodesE1-En. As discussed in more detail below, the monitoring circuitry canmonitor voltages across components of the stimulation output circuitry309.

The stimulation output circuitry 309 includes circuitry for generatingelectrical stimulation energy in accordance with a defined pulsedwaveform having a specified pulse amplitude, pulse rate, pulse width,pulse shape, and burst rate under control of control logic 310. Thestimulation output circuitry 309 is coupled to the electrodes E1-En andincludes drivers for the electrodes, with a digital-to-analog converter(DAC) 311 being responsive to the stimulation program to supply thespecified electrode currents. The electrodes E1-En are coupled tocapacitors C1-Cn, which prevent injection of DC current into thepatient's tissue. Clock circuitry 312 and V+ generation circuitry 314will be discussed in more detail below. For now, merely note that V+generation circuitry provides a high voltage, V+ (referred to ascompliance voltage, typically on the order of about 15 V) by boostingthe voltage provided by the power source 308 (referred to as Vbat,typically about 3 V). For reasons explained below, DAC 311 requires ahigh voltage source V+ to operate properly.

FIG. 4 illustrates a circuit 400 through which stimulation currentI_(out) flows when stimulating a patient using electrodes E1 and En. Theresistance of the patient's tissue is represented by a resistorR_(Tissue). In the illustrated circuit 400, electrode E1 is an anode,i.e., a current source, and electrode En is a cathode, i.e., a currentsink. The magnitude of current, I_(out), and the amount of time it isapplied (the pulse width) is prescribed by the therapy that the patientis to receive. The DAC circuitry 311 sets the current I_(out) based ondigital control signals, for example, from control logic circuitry 310(see FIG. 3). DAC circuitry that sources anodic current is referred toas a PDAC; DAC circuitry that sinks cathodic current is referred to asan NDAC. The compliance voltage V+ provides the driving force forI_(out). Each element of circuit 400 drops some portion of compliancevoltage V+. The voltage drops can be denoted as follows: V_(P) is thevoltage drop across the PDAC, Vc1 drops across the capacitor C1, V_(R)drops across the resistance due to the patient's tissue, Vc3 dropsacross the capacitor Cn, and V_(N) drops across the NDAC. The totalvoltage drop is V+=V_(P)+VC1+V_(R)+Vcn+V_(N). The voltage drop throughthe tissue, V_(R), is difficult to know a priori, but in any event willremaining constant over the duration of a current pulse. By contrast,the voltage drops across the decoupling capacitors, Vc1 and Vc2, willincrease as current is injected through them the capacitors.

If V+ is set to a constant value, the voltage drops across the PDAC andNDAC (i.e., V_(P) and V_(N), respectively) will necessarily decreasebecause Vc1 and Vc2 increase. The changing voltage drops of the PDAC andNDAC can cause problems because those elements contain outputtransistors that operate at optimal voltages. The optimal voltage forthe PDAC V_(P) (opt) is typically about 1.5V and the optimal voltage forthe NDAC V_(N) (opt) is typically about 1.2V. (The difference betweenthe values of V_(P) (opt) and V_(N) (opt) is because the PDAC usesp-channel transistors and the NDAC uses n-channel transistors). When thePDAC and/or NDAC operate below the optimal voltage, they are not able toprovide the desired current. Operating above the optimal voltage wastespower and generates unnecessary heat. It is therefore desirable tooperate the PDAC and the NDAC at or just slightly above the optimalvoltages. The compliance voltage V+ often needs to be adjusted to aproper value for allowing the PDAC and NDAC to operate at their optimalvalues.

FIG. 5 illustrates aspects of the V+ generation circuitry 314 thatprovides V+. The V+ generation circuitry includes a boost convertercircuit 403 that provide that comprises a capacitor 402, an inductor407, a transistor 406 and a diode 408. The power source 308 provides avoltage Vbat to the boost converter circuit 403. When the transistor 406is on, current flows through the inductor 407 to ground. When thetransistor 406 is off current in the inductor 407 discharges through thediode 408 to the charging capacitor 402. The charge building on thecharging capacitor is the compliance voltage V+. The turning on and offof the inductor is controlled by its gate voltage, V_(G), which is anoscillating clock signal CLK modulated by a pulse width modulator 405.

V+ monitor and adjust logic circuitry 404 (which may comprise part ofthe IPG's microcontroller 302 or the IPG's monitoring circuitry 313, ormay be a standalone circuit block) adjusts V+ so that the DACs operateat optimum voltages. Details about how the V+ monitor and adjust logiccircuitry 404 works are well described in the prior art, and are notdescribed here in detail. See, for example, U.S. Pat. No. 8,175,719,issued May 8, 2012; U.S. Pat. No. 9,174,051, issued Nov. 3, 2015; andU.S. Pat. No. 9,314,632, issued Apr. 19, 2016, the entire contents ofeach being incorporated herein by reference. Briefly, the V+ monitor andadjust logic circuitry 404 includes voltage sensing circuitry thatsenses the voltages V_(P) and V_(N) at the PDAC and NDAC. If V_(P)and/or V_(N) falls below an optimum operating value, the V+ monitor andadjust logic circuitry executes an algorithm to determine an amount toincrease V+ and outputs an appropriate “boost” signal to the pulse widthmodulator 405.

The boost signal instructs the pulse width modulator 405 how to adjustthe pulse width of a clock signal, CLK, thereby determining how V_(G) ismodulated. How the pulse width modulator 405 modulates V_(G) determinesthe percentage of time the transistor 406 is turned on, referred to asthe transistor's duty cycle. The V+ monitor and adjust logic circuitryincreases the duty cycle of the transistor 406 to increase V+ anddecreases the duty cycle to decrease V+. The reason for this isexplained in more detail below.

The inventors have discovered that a boost converter circuit, such asthe one illustrated in FIG. 5, can be used to detect and monitor thepresence of a magnetic field, such as a magnetic field associated withan MRI. FIG. 6 is a simplified illustration of a boost converter circuit600 and aspects of related logic useful for illustrating how the circuitcan be used to detect the presence of a magnetic field. As with theboost converter circuit 403 of FIG. 5, circuit 600 of FIG. 6 includes acapacitor 402, an inductor 407, a transistor 406 and a diode 408. Theinductor 407 includes a ferrite core provided by a section of a toroidalferrite magnet 503. While a toroidal magnet is shown in FIG. 6, othergeometries can be used. In circuit 600, a current I_(out) is provided toa generic load 610, which can be thought of as the circuit through theDACs, coupling capacitors, and tissue resistance, illustrated in FIG. 5.

As explained above, when the transistor 406 is on, current flows throughthe inductor 407 to ground. When the transistor 406 is off current inthe inductor 407 discharges through the diode 408 to the chargingcapacitor 402. FIG. 7 illustrates the current IL through the inductorand the voltage V_(L) at node 620 as a function of the oscillating gatevoltage V_(G). The top line shows V_(G). The charge phase 701 a is thetime that the transistor 406 is turned on and current is flowing throughthe inductor 407 to ground. The discharge phase 701 b is when thetransistor 406 is turned off and charge stored in the inductor 407 canflow through diode 408.

The middle line IL represents the current across the inductor 407.During the charge phase the inductor current rises linearly to a peakcurrent I_(PK), according to Eq. 1:

$\begin{matrix}{\frac{dI}{dt} = \frac{V_{bat}}{L}} & {{Eq}.\mspace{14mu} 1}\end{matrix}$

where L is the inductance of the inductor 407. The peak current I_(PK)can be calculated by Eq. 2:

$\begin{matrix}{I_{PK} = \frac{V_{bat}T}{L}} & {{Eq}.\mspace{14mu} 2}\end{matrix}$

where T is time of a single charge phase.

Assume that the transistor is turning on and off such that period for asingle on-off cycle is P and that the percentage of time that thetransistor is on during a single cycle is D (the duty cycle). Then T=DP.Since the frequency f is 1/P, the formula for the peak current I_(PK)can be rewritten in terms of frequency and duty cycle as shown in Eq. 3:

$\begin{matrix}{I_{PK} = \frac{V_{bat}D}{2{Lf}}} & {{Eq}.\mspace{14mu} 3}\end{matrix}$

As the current flows through the inductor 407, energy is stored in theinductor's magnetic field. That energy is described by Eq. 4:

E=1/2LI_(PK) ²   Eq. 4

When the transistor 406 is turned off at the beginning of the dischargephase, the current through the inductor 407 rapidly drops, producing aback e.m.f. in the inductor 407. The energy stored in the inductor 407is discharged through the diode 408 and the voltage V_(L) at node 620swings high to a peak voltage V_(L, Peak). Current flows through thediode 408 to the capacitor 409 during the discharge phase if V_(L) isgreater than V+. As shown in the energy equation, the amount of energytransferred increases as the square of the peak current I_(PK).Moreover, I_(PK) increases as a function of the duty cycle D. Thus,increasing the duty cycle D increases the current discharged through thediode 408, thereby increasing the compliance voltage V+.

Recall from the discussion of FIG. 5, that the V+ monitor and adjustlogic circuitry 404 executes an algorithm based on the voltages V_(P)and V_(N) of the DACS to determine if the compliance voltage V+ shouldbe adjusted and then provides an appropriate boost signal to adjust theduty cycle of the transistor 406 accordingly. That aspect of the V+monitor and adjust logic circuitry 404 is illustrated in FIG. 6 as acomparator circuit 504 and a current controlled oscillator 630. Thecomparator circuit includes a comparator 640 that is configured tocompare the value of V+ (adjusted by a voltage divider circuitcomprising R1 and R2) with a reference voltage V_(ref). The value ofV_(ref) is programmed algorithmically based on measurements of V_(P) andV_(N). If the divided V+ falls below the programmed value of V_(ref),the comparator 640 sends an output to the current controlled oscillatorand pulse width modulator 405 that increases the duty cycle of thevoltage signal provided to the gate of the transistor 406, therebyincreasing V+. When the adjusted value of V+ exceeds V_(ref), thecomparator sends a signal that decreases the duty cycle of the voltagesignal provided to the gate of the transistor 406.

In the absence of an external magnetic field, the inductance of theinductor 407 remains constant. However, when it is subject to a strongmagnetic field, the magnet 503 at the core of the inductor “saturates,”meaning that it becomes less able to support magnetic field generated bycharges moving within the wire coil of the inductor. As a result, theinductance of the inductor 407 decreases in the presence of an externalmagnetic field. The inductance drops by about two orders of magnitude ina 1.5 tesla external magnetic field, such that the inductor 407 behavesessentially like an air-core inductor. Curve 650 of FIG. 6 illustratesthe drop in inductance as a function of magnetic field, H.

From equations Eq. 1-Eq. 3, it is apparent that when the inductance L ofthe inductor 407 decreases due to saturation, dI/dt and I_(PK) increase.Consequently, the magnitude of the spike in voltage V_(L,Peak) at node620 also increases. The dashed lines in FIG. 8 show the changes inI_(PK) and V_(L, Peak) when the inductance L of the inductor 407decreases due to saturation.

The increase in the magnitude of V_(L, Peak) as a consequence of theinductor core becoming saturated can be used to detect when the IPG isin a magnetic field. Moreover, when V_(L) increases V+ also increases.Referring to FIG. 6, the relationship between the inductance L of theinductor 407, the output current I_(out), the compliance voltage V+, thebattery voltage V_(bat), the frequency f and duty cycle D of gatevoltage V_(G) is defined by the duty cycle equation, Eq. 5:

$\begin{matrix}{D = \sqrt{\frac{\left( {V +} \right) - V_{bat}}{V_{bat}^{2}}2I_{Out}{fL}}} & {{Eq}.\mspace{14mu} 5}\end{matrix}$

Each of the variables of Eq. 5 are very precisely known in theIPG—V_(bat) and I_(out) are monitored using monitoring circuitry 313(FIG. 3); f is the frequency of the current controlled oscillator 630; Dis the duty cycle of the pulse width modulator 405; and V+ is set by theV+ monitor and adjust logic circuitry and can also be independentlymeasured using the monitoring circuitry 313. Finally, L is theinductance of the inductor 407 and is known (in the absence of anexternal magnetic field) because the inductor is chosen by design.

However, when the IPG is within an external magnetic field that isstrong enough to begin saturating the core of the inductor 407, themeasured V+ will not agree with the value calculated according to Eq. 5using the known values for the variables. Instead, the measured V+ willexceed the expected value because the inductance L will be less thanexpected.

According to some embodiments, the IPG periodically measures V+. Forexample, the IPG may use the monitoring circuitry 313 to measure V+every second or multiple times per second, such as three times persecond. If the monitoring circuitry senses a sudden increase in V+, thenthe IPG can be instructed to activate its MRI-safe mode. According tosome embodiments, the monitoring circuitry may compare the increase inV+ to threshold value (3 V, for example) and set the IPG to MM-safe modeonly if the increase exceeds that threshold value.

As mentioned above, entering MRI-safe mode may cause the IPG to take oneor more actions, such as: (1) ceasing to provide stimulation to thepatient, (2) increasing the compliance voltage V+ to prevent unwantedinduced current through the IPG, (3) confirming that the battery isfully charged, (4) suspending passive charge recovery.

FIG. 9 illustrates an alternative process for determining the presenceof an external magnetic field based on saturation the inductor magnet.Periodically during operation, the IPG's monitoring circuitry 313measures V+ and compares the measured V+ to an expected value of V+ thatis calculated using the duty cycle equation (Eq. 5) based on measuredvalues of Vbat and I_(out), set values of f and D, and the nominal valueof L. If the measured value of V+ is greater than the expected value,then the IPG executes an algorithm that uses Eq. 5 to calculate the trueinductance L based on the measured value of V+ and the other knownvariables.

If the calculated inductance is less than the nominal inductance (i.e.,the inductance rating of the inductor used in the circuit), then it isassumed that the inductor is at least partially saturated due to thepresence of an external magnetic field. According to some embodiments,the IPG can calculate the strength of the external magnetic field basedon a function relating the inductance to magnetic field strength. Such afunction would have to have been calculated empirically beforehand andprogrammed into the IPG. FIG. 11 illustrates inductance v. magneticfield relationships calculated empirically for two inductors.

The IPG can take steps to enter MM-safe mode if the calculated magneticfield exceeds a threshold value. In alternative embodiments wherein theIPG is not programmed to calculate the strength of the magnetic field,the IPG can take steps to enter an MM-safe mode based on the calculateddecrease in inductance. Moreover, the IPG can take steps to enter anMM-safe mode based on an increase in V+, as mentioned above.

According to a further embodiment, the IPG is already in an MM-safe modeand executes an algorithm to adjust the duty cycle of the pulse widthmodulator 405 (FIG. 6) based on the strength of an external magneticfield. Recall that in MM-safe mode, the IPG sets the compliance voltageV+ to a high level to prevent unwanted induced current through the IPG.Referring to FIG. 6, the IPG would generally increase the duty cycle ofthe pulse width modulator 405, for example by increasing the value ofVref in the comparator circuit 504, in order to drive the compliancevoltage V+ to the high value needed in MM-safe mode. But if theinductance of the inductor 407 drops significantly due to saturation bythe external magnetic field, a higher than expected current will runthrough the transistor 406 when the transistor is on. If the duty cycleis too great (i.e., the transistor is on for too much of the time), thenso much current may flow through the transistor that it fails, acondition known as runaway.

FIG. 10 illustrates a process for moderating the duty cycle of the pulsewidth modulator 405 (and thereby the time transistor 406 is on) so as toprevent runaway while setting an adequate compliance voltage V+ inMRI-safe mode. The process begins when the IPG is in MRI-safe mode.Rather than immediately increasing the duty cycle to drive V+ high, theduty cycle is set low and the IPG's monitoring circuitry 313 measuresV+. The IPG determines if the target V+ value has been reached and alsodetermines if the pulse width modulator 405 is providing a duty cyclethat is greater than or equal to the maximum duty cycle D_(max). D_(max)is generally a design constraint of the particular IPG implementationand is determined based on factors that are not relevant here. Forpresent purposes, it need only be appreciated that D_(max), if itexists, is a constraint built into the IPG system.

If neither the D_(max) or V+_(max) conditions are met, then the IPGincrementally increases the duty cycle and re-executes the measurementand determinations at the new increased duty cycle. If either V+_(max)or D_(max) are met, then the IPG ceases incrementing D. The IPG then cancalculate the inductance L using Eq. 5. According to some embodiments,the IPG can calculate the magnetic field strength H, from empiricallyderived data as described above.

It should be noted here that the circuit described herein and used forinduction-based determination of an external magnetic field is a boostcircuit that is commonly used to provide a compliance voltage in an IPG.Extending the boost circuit for magnetic field detection offersadvantages in space saving and design considerations, especiallycompared to using Hall effect transistors. However, it should beappreciated that a circuit, similar to the one illustrated in FIG. 6,can be implemented as a “stand-alone” sensor for magnetic fielddetection. In other words, it is not required that the same circuit beused for both compliance voltage and magnetic field detection.

Although particular embodiments of the present invention have been shownand described, it should be understood that the above discussion is notintended to limit the present invention to these embodiments. It will beobvious to those skilled in the art that various changes andmodifications may be made without departing from the spirit and scope ofthe present invention. Thus, the present invention is intended to coverequivalents that may fall within the spirit and scope of the presentinvention as defined by the claims.

What is claimed is:
 1. An implantable pulse generator (IPG) configuredto provide therapy to a patient, the IPG comprising: first circuitryconfigured to boost a first voltage to a second voltage, the firstcircuitry comprising a magnetic-core inductor having an inductance, andsecond circuitry configured to detect a change in a parameter of thefirst circuitry, the change in the parameter indicating a change in theinductance when the IPG is in the presence of an external magneticfield.
 2. The IPG of claim 1, wherein the parameter is the secondvoltage.
 3. The IPG of claim 1, wherein the parameter is the inductance.4. The IPG of claim 1, wherein the first circuit further comprises: atransistor configured to receive a gate voltage, the gate voltage havingan oscillation frequency and being modulated by a pulse width modulatorhaving a duty cycle, and an output stage configured to use the secondvoltage to drive a known current through a load, wherein detecting achange in a parameter comprises: calculating an expected second voltagevalue from known values of the current, the first voltage, theoscillation frequency, and the duty cycle, and an assumed value for theinductance, measuring the second voltage, and comparing the secondvoltage to the calculated expected second voltage.
 5. The IPG of claim4, wherein detecting a change in a parameter further comprisescalculating the inductance based on the measured second voltage.
 6. TheIPG of claim 5, further comprising a processor configured to determinean external magnetic field strength based on the calculated inductance.7. The IPG of claim 1, wherein the IPG is configured to change from afirst operational mode or a second operational mode based on a detecteda change in a parameter of the first circuitry.
 8. The IPG of claim 1,wherein the first operational mode is a normal mode and the secondoperational mode is an MM-safe mode.
 9. The IPG of claim 1, wherein thefirst circuit is a boost converter circuit configured to provide acompliance voltage and wherein the second voltage is the compliancevoltage.
 10. An implantable pulse generator (IPG) configured to providetherapy to a patient, the IPG comprising: first circuitry configured toboost a first voltage to a compliance voltage, the first circuitrycomprising: a magnetic-core inductor having an inductance, a transistorconfigured to receive a gate voltage, the gate voltage having anoscillation frequency and being modulated by a pulse width modulatorhaving a duty cycle, and an output stage configured to use thecompliance voltage to drive a known current through a load, wherein theIPG is configured to increase the compliance voltage by: setting theduty cycle to a low value, measuring the compliance voltage, increasingthe duty cycle until either a predetermined maximum duty cycle or apredetermined maximum compliance voltage is reached.
 11. The IPG ofclaim 10, wherein the IPG is further configured to calculate theinductance from the measured compliance voltage, and known values of thecurrent, the first voltage, the oscillation frequency, and the dutycycle.
 12. The IPG of claim 11, wherein the IPG is further configured todetermine an external magnetic field strength based on the calculatedinductance.
 13. A circuit for detecting if an implantable pulsegenerator (IPG) is within a magnetic field, the circuit comprising: aninductor having an inductance, and a measuring circuitry configured todetermine a decrease in the inductance.
 14. The circuit of claim 13,configured to boost a first voltage to a compliance voltage.
 15. Thecircuit of claim 14, further comprising: a transistor configured toreceive a gate voltage, the gate voltage having an oscillation frequencyand being modulated by a pulse width modulator having a duty cycle, andan output stage configured to use the compliance voltage to drive aknown current through a load, wherein determining a decrease in theinductance comprises: calculating an expected compliance voltage fromknown values of the current, the first voltage, the oscillationfrequency, and the duty cycle, and an assumed value for the inductance,measuring the compliance voltage, and comparing the compliance voltageto the calculated expected compliance voltage.
 16. The circuit of claim15, wherein the circuit is configured to calculate the inductance fromthe measured compliance voltage, and known values of the current, thefirst voltage, the oscillation frequency, and the duty cycle.